package com.faner.fast.base;

import lombok.Data;

import java.util.ArrayList;
import java.util.List;

/**
 * @作者 faner
 * @创建时间 2021/1/26 12:26
 */
@Data
public class TreeNode {

    protected long id;

    protected long parentId;

    protected List<TreeNode> children = new ArrayList<TreeNode>();

    protected Boolean hasChildren;

    public void add(TreeNode node) {
        children.add(node);
    }

}
